Electrode position detection

ABSTRACT

Devices, systems, and techniques are disclosed for determining spatial relationships between electrodes implanted within a patient. In one example, a medical device delivers, via a first electrode, an electrical stimulus and senses, for each other electrode, a respective electrical signal indicative of the electrical stimulus. The medical device determines, for each other electrode, a respective value for each respective electrical signal. The medical device determines, based on the respective values for each respective electrical signal and values of tissue conductivity of tissues of the patient interposed between the first electrode and the other electrodes, spatial relationships between the first electrode and each other electrode of the plurality of electrodes.

This application is a divisional application claiming priority to U.S.patent application Ser. No. 16/858,030, filed Apr. 24, 2020, the entirecontents of which is incorporated herein by reference.

TECHNICAL FIELD

This disclosure generally relates to medical therapy and, moreparticularly, electrical stimulation therapy.

BACKGROUND

Medical devices, including implantable medical devices (IMDs), may beused to treat a variety of medical conditions. Medical electricalstimulation devices, for example, may deliver electrical stimulationtherapy to a patient via external and/or implanted electrodes.Electrical stimulation therapy may include stimulation of nerve tissue,muscle tissue, the brain, the heart, or other tissue within a patient.In some examples, an electrical stimulation device is fully implantedwithin the patient. For example, an implantable electrical stimulationdevice may include an implantable electrical stimulation generator andone or more implantable leads carrying electrodes. Alternatively, theelectrical stimulation device may comprise a leadless stimulator. Insome cases, implantable electrodes may be coupled to an externalelectrical stimulation generator via one or more percutaneous leads orfully implanted leads with percutaneous lead extensions.

Medical electrical stimulators have been proposed for use to relieve avariety of symptoms or conditions such as chronic pain, tremor,Parkinson's disease, depression, epilepsy, migraines, urinary or fecalincontinence, pelvic pain, sexual dysfunction, obesity, andgastroparesis. An electrical stimulator may be configured to deliverelectrical stimulation therapy via leads that include electrodesimplantable proximate to the spinal cord, pelvic nerves,gastrointestinal organs, sacral nerves, peripheral nerves, or within thebrain of a patient. Stimulation may be delivered from electrodesimplanted proximate the spinal cord, proximate the sacral nerve, withinthe brain, and proximate peripheral nerves are often referred to asspinal cord stimulation (SCS), sacral neuromodulation (SNM), deep brainstimulation (DBS), and peripheral nerve stimulation (PNS), respectively.

SUMMARY

In general, the disclosure describes methods, devices, systems, andtechniques for determining spatial relationships, such as distances,between electrodes implanted within a patient. For example, the medicaldevice may be configured to deliver, via a first electrode of theplurality of electrodes, an electrical stimulus defined by at least oneparameter. In some examples, the at least one parameter is a firstvoltage amplitude. The medical device may also be configured to sense,via each of the other electrodes of the plurality of electrodes,respective electrical signals indicative of the electrical stimulus. Insome examples, the respective electrical signals are indicative ofsecond voltage amplitude values sensed by each other electrode of theplurality of electrodes. The medical device can then determine, based onthe respective values for each respective electrical signal sensed byeach other electrode of the plurality of electrodes, spatialrelationships, such as distances, of the first electrode to each of theother electrodes of the plurality of electrodes. In some examples, themedical device may repeat the foregoing process to determine a distancebetween each pair of electrodes of the plurality of electrodes. Theplurality of electrodes may be carried by two or more differentimplantable structures, such as two or more implantable medical leads.

In some examples, the medical device selects, based on the spatialrelationships of the first electrode to each of the other electrodes,one or more electrodes for delivering electrical stimulation therapy andthen delivers electrical stimulation therapy via the selected one ormore electrodes. In other examples, the medical device may determine anamplitude or other parameter defining electrical stimulation based atleast in part on a spatial relationship between two or more electrodes.In some examples, the medical device selects, based on the spatialrelationships of the first electrode to each of the other electrodes,one or more electrodes for sensing a biosignal of the patient and thensenses a biosignal of the patient via the selected one or moreelectrodes. In some examples, the medical device outputs, for display toa user, a representation of the plurality of electrodes depicting thespatial relationship between at least some of the plurality ofelectrodes.

In one example, a medical device senses impedances between the firstelectrode and each of the other electrodes. The medical device can thendetermine, based on the sensed impedances, a type of a tissue interposedbetween the first electrode to each of the other electrodes. Further,the medical device can determine, based on the type of the tissue, atissue conductivity of the tissues interposed between the firstelectrode to each of the other electrodes. The medical device may useboth the values of a tissue conductivity of tissues interposed betweenthe plurality of electrodes and the respective values for eachrespective electrical signal sensed by each other electrode of theplurality of electrodes to determine the spatial relationships of thefirst electrode to each of the other electrodes of the plurality ofelectrodes.

In one example, this disclosure describes a method comprising:controlling, by processing circuitry of a medical device, stimulationgeneration circuitry to deliver, via a first electrode of a plurality ofelectrodes, an electrical stimulus; sensing, by sensing circuitry andfor each other electrode of the plurality of electrodes, a respectiveelectrical signal indicative of the electrical stimulus; determining, bythe processing circuitry and for each other electrode, a respectivevalue for each respective electrical signal; and determining, by theprocessing circuitry, and based on the respective values for eachrespective electrical signal sensed by each other electrode of theplurality of electrodes, spatial relationships between the firstelectrode and each other electrode of the plurality of electrodes.

In another example, this disclosure describes a medical device systemcomprising: stimulation generation circuitry configured to deliverelectrical stimulation via a first electrode of a plurality ofelectrodes; and processing circuitry configured to control thestimulation generation circuitry to deliver, via the first electrode, anelectrical stimulus; sensing circuitry configured to sense, for eachother electrode of the plurality of electrodes, a respective electricalsignal indicative of the electrical stimulus, wherein the processingcircuitry is further configured to determine, for each other electrode,a respective value for each respective electrical signal, and whereinthe processing circuitry is further configured to determine, based onthe respective values for each respective electrical signal sensed byeach other electrode of the plurality of electrodes, spatialrelationships between the first electrode and each other electrode ofthe plurality of electrodes.

In another example, this disclosure describes a non-transitorycomputer-readable medium comprising instructions that, when executed,are configured to cause processing circuitry of a medical device to:control stimulation generation circuitry of the medical device todeliver, via a first electrode of a plurality of electrodes, anelectrical stimulus; control sensing circuitry to sense, for each otherelectrode of the plurality of electrodes, a respective electrical signalindicative of the electrical stimulus; determine, for each otherelectrode, a respective value for each respective electrical signal; anddetermine, based on the respective values for each respective electricalsignal sensed by each other electrode of the plurality of electrodes,spatial relationships between the first electrode and each otherelectrode of the plurality of electrodes.

In another example, this disclosure describes a method comprising:sensing, by sensing circuitry of a medical device and for each electrodeof a plurality of electrodes, a respective electrical signal indicativeof a cardiac signal of a heart of a patient; determining, by theprocessing circuitry and for each electrode of the plurality ofelectrodes, a respective value for each respective electrical signal;and determining, by the processing circuitry, and based on therespective values for each respective electrical signal sensed by eachelectrode of the plurality of electrodes, a spatial relationship betweeneach electrode of the plurality of electrodes and the heart of thepatient.

In another example, this disclosure describes a medical device systemcomprising: sensing circuitry of a medical device configured to sense,for each electrode of a plurality of electrodes, a respective electricalsignal indicative of a cardiac signal of a heart of a patient; andprocessing circuitry configured to: determine, for each electrode of theplurality of electrodes, a respective value for each respectiveelectrical signal; and determine, based on the respective values foreach respective electrical signal sensed by each other electrode of theplurality of electrodes, a spatial relationship between each electrodeof the plurality of electrodes and the heart of the patient.

The details of one or more examples of the techniques of this disclosureare set forth in the accompanying drawings and the description below.Other features, objects, and advantages of the techniques will beapparent from the description and drawings, and from the claims.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1 is a schematic diagram illustrating an example implantablestimulation system including an implantable medical device, a pair ofimplantable stimulation electrode arrays carried by implantable leads,and an external programmer in accordance with the techniques of thedisclosure.

FIG. 2 is a functional block diagram illustrating an example of the IMDof FIG. 1 in further detail.

FIG. 3 is a functional block diagram illustrating an example of theexternal programmer of FIG. 1 in further detail.

FIG. 4 is a conceptual illustration of example electrodes in accordancewith the techniques of the disclosure.

FIG. 5 is a flowchart illustrating an operation in accordance with thetechniques of the disclosure.

FIG. 6 is an illustration depicting an example user interface of theexternal programmer of FIG. 3 .

FIGS. 7A-7B are conceptual illustrations of example electrodes inaccordance with the techniques of the disclosure.

FIG. 8 is a conceptual illustration of example electrodes in accordancewith the techniques of the disclosure.

Like reference characters refer to like elements throughout the figuresand description.

DETAILED DESCRIPTION

This disclosure describes devices, systems, and techniques fordetermining spatial relationships, such as distances, between electrodesimplanted within a patient. A medical device, such as an IMD or externalstimulator, typically delivers electrical stimulation therapy and/orsenses a biosignal of the patient via a plurality of electrodes disposedon one or more leads. The one or more leads are typically implanted inthe epidural space for spinal cord stimulation, but other locations arepossible for other therapies or sensing targets. The location of theelectrodes carried by the one or more leads along the spinal corddirectly effects the efficacy of stimulation therapy directed to nervesof the spinal cord. An implantable medical device may utilize a specificelectrode combination to provide fine tuning of the shape of theelectrical field produced by electrical stimulation delivered via theelectrode combination selected from the plurality of electrodes.

Clinicians typically implant each lead to a desired location within theanatomy of the patient. However, the precise location of the leads withrespect to each other and/or target anatomy may not result as intendedby the clinician. For example, the implanted leads may not be parallelto one another and/or one or more leads may have a slight curve thataffects the final location of the electrodes. Further, the leads of themedical device may shift over time, either axially or laterally withinthe tissue. Fluoroscopy may be capable of determining a true location ofthe leads, and the electrodes disposed on the leads, within the patient.However, such imaging of the leads is not a practical solution for allpatients or while the patient is receiving therapy. Therefore, withoutknowing the location of the electrodes, efficacy of the deliveredtherapy may be reduced or more time may be required by the clinician tofind appropriate parameters for electrical stimulation therapy usingelectrodes at unknown locations (e.g., by trial and error).

The techniques described herein enable a medical device to determine aspatial relationship, e.g. a distance, of each electrode to each otherelectrode. For example, the medical device may serially activate eachelectrode independently while recording from the remaining electrodes.The medical device may utilize the relative voltages recorded from eachelectrode to approximate the distances between each electrode. In someexamples, the medical device may incorporate tissue conductivity toestimate distances between electrodes. For example, the medical devicemay make the assumption that the tissue of the patient between theelectrodes is of a uniform type, such as the epidural space in thespinal cord, that is a consistent electrical conducting medium. Themedical device may also apply an assumed known conductivity of thetissue. The medical device may store the conductivity of the tissue,e.g., the epidural space, in memory and use the conductivity todetermine a relative location or distance of the electrodes with respectto one another. In other examples, the medical device may back-calculatethe conductivity of the epidural space using a known contact separationdistance on the same lead. In this manner, a medical device may converta set of voltages for each electrode relative to each other electrodeinto a spatial relationship, such as a distance, using theassumed/calculated resistivity of the medium between them. The medicaldevice may use the determined spatial relationships to perform otheractions. As some examples, the medical device may adjust one or moreparameter values in order to automate focal field targeting forelectrical stimulation, compensate for lead migration, perform real-timeelectrical stimulation therapy parameter adjustment to keep anelectrical field consistent during inter-lead movements, or providelocation information to reduce the need for fluoroscopy to identify leadpositions. In some other examples, the medical device or other devicemay use the spatial relationships between electrodes to generate avisual representation of the position of the electrodes, and/or leadsupon which they are carried, with respect to each other and/or one ormore anatomical structures of the patient.

The methods, devices, systems, and techniques of the disclosure mayprovide specific improvements to the field of electrical stimulationtherapy that have practical applications. For example, the techniquesdescribed herein may enable a medical device, such as an IMD, toaccurately measure distances between electrodes disposed on differentleads implanted within a patient. Furthermore, the techniques describedherein may enable a medical device, such as an IMD or externalprogrammer, to generate a representation of the position of theelectrodes relative to one another for display to a clinician. Such arepresentation may depict a position of each of the plurality ofelectrodes relative to one another with a high degree of accuracy. Byaccurately identifying the distances between multiple electrodes ofleads, the techniques described herein may enable a clinician and/or amedical device to select electrodes suited for delivery of efficaciouselectrical stimulation therapy or sensing of biosignals from thepatient, thereby increasing the efficacy of electrical stimulationtherapy and/or decreasing the risk of side effects of the electricalstimulation therapy. Further, the techniques of the disclosure mayenable the identification of anatomical structures within tissues of thepatient, such as soft tissue structures within the patient.

FIG. 1 is a schematic diagram illustrating an example implantablestimulation system 10 including IMD 14, a pair of implantable electrodearrays in the form of stimulation leads 16A and 16B, and externalprogrammer 20. Although the techniques described in this disclosure maybe generally applicable to a variety of medical devices includingexternal and IMDs, application of such techniques to IMDs and, moreparticularly, implantable electrical stimulators such asneurostimulators will be described for purposes of illustration. Moreparticularly, the disclosure will refer to an implantable spinal cordstimulation (SCS) system for purposes of illustration, but withoutlimitation as to other types of medical devices.

As shown in FIG. 1 , system 10 includes an IMD 14 and externalprogrammer 20 shown in conjunction with a patient 12. In the example ofFIG. 1 , IMD 14 is an implantable electrical stimulator configured forspinal cord stimulation (SCS), e.g., for relief of chronic pain or othersymptoms. Again, although FIG. 1 shows an implantable medical device,other embodiments may include an external stimulator, e.g., withpercutaneously implanted leads, or implanted leads with percutaneouslead extensions. Stimulation energy is delivered from IMB 14 to spinalcord 18 of patient 12 via one or more electrodes disposed on implantableleads 16A and 16B (collectively “leads 16”). In some applications, suchas spinal cord stimulation (SCS) to treat chronic pain, the adjacentimplantable leads 16 may have longitudinal axes that are substantiallyparallel to one another.

Although FIG. 1 is directed to SCS therapy, system 10 may alternativelybe directed to any other condition that may benefit from stimulationtherapy. For example, system 10 may be used to deliver stimulation toone or more tissues in order to treat tremor, Parkinson's disease,epilepsy, urinary or fecal incontinence, sexual dysfunction, obesity, orgastroparesis. In this manner, system 10 may be configured to providetherapy taking the form of deep brain stimulation (DBS), pelvic floorstimulation, gastric stimulation, or any other stimulation therapy. Inaddition, patient 12 is ordinarily a human patient.

Each of leads 16 may include electrodes and the parameters for a programthat controls delivery of stimulation therapy by IMB 14 may includeinformation identifying which electrodes have been selected for deliveryof stimulation according to a stimulation program, the polarities of theselected electrodes, i.e., the electrode configuration for the program,and voltage or current amplitude, pulse rate, and pulse width ofstimulation delivered by the electrodes. Delivery of stimulation pulseswill be described for purposes of illustration. However, stimulation maybe delivered in other forms such as continuous waveforms. Programs thatcontrol delivery of other therapies by IMD 14 may include otherparameters, e.g., such as dosage amount, rate, or the like for drugdelivery.

In the example of FIG. 1 , leads 16 carry one or more electrodes thatare placed adjacent to the target tissue of the spinal cord. One or moreelectrodes may be disposed at a distal tip of a lead 16 and/or at otherpositions at intermediate points along the lead. Leads 16 may beimplanted and coupled to IMD 14. In some examples, leads 16, and the oneor more electrodes disposed on leads 16, are implanted within anepidural space of the patient. Alternatively, as mentioned above, leads16 may be implanted and coupled to an external stimulator, e.g., througha percutaneous port. In some cases, an external stimulator may be atrial or screening stimulation that used on a temporary basis toevaluate potential efficacy to aid in consideration of chronicimplantation for a patient. In additional embodiments, IMD 14 may be aleadless stimulator with one or more arrays of electrodes arranged on ahousing of the stimulator rather than leads that extend from thehousing.

The stimulation may be delivered via selected combinations of electrodescarried by one or both of leads 16, e.g., in bipolar, unipolar, ormultipolar combinations. The target tissue may be any tissue affected byelectrical stimulation energy, such as electrical stimulation pulses orwaveforms. Such tissue includes nerves, smooth muscle, and skeletalmuscle. In the example illustrated by FIG. 1 , the target tissue isspinal cord 18. Stimulation of spinal cord 18 may, for example, preventpain signals from traveling through the spinal cord and to the brain ofthe patient. Patient 12 may perceive the interruption of pain signals asa reduction in pain and, therefore, efficacious therapy results.

The deployment of electrodes via leads 16 is described for purposes ofillustration, but arrays of electrodes may be deployed in differentways. For example, a housing associated with a leadless stimulator maycarry arrays of electrodes, e.g., rows and/or columns (or otherpatterns), to which multiplexing operations may be applied. Suchelectrodes may be arranged as surface electrodes, ring electrodes, orprotrusions. As a further alternative, electrode arrays may be formed byrows and/or columns of electrodes on one or more paddle leads. In someembodiments, electrode arrays may include electrode segments, which maybe arranged at respective positions around a periphery of a lead, e.g.,arranged in the form of one or more segmented rings around acircumference of a cylindrical lead. Other electrode and leadconfigurations may be adapted for use with the present disclosure solong as they enable IMD 14 to electrically stimulate and sense from atarget tissue.

In the example of FIG. 1 , stimulation energy is delivered by IMD 14 tothe spinal cord 18 to reduce the amount of pain perceived by patient 12.As described above, IMD 14 may be used with a variety of different paintherapies, such as peripheral nerve stimulation (PNS), peripheral nervefield stimulation (PNFS), DBS, cortical stimulation (CS), sacralneuromodulation (SNM), pelvic floor stimulation, gastric stimulation,and the like. The electrical stimulation delivered by IMD 14 may takethe form of electrical stimulation pulses or continuous stimulationwaveforms, and may be characterized by controlled voltage levels orcontrolled current levels, as well as pulse width and pulse rate (i.e.,pulse frequency) in the case of stimulation pulses.

In some examples, IMD 14 may deliver stimulation therapy according toone or more programs. A program defines one or more parameters thatdefine an aspect of the therapy delivered by IMD 14 according to thatprogram. For example, a program that controls delivery of stimulation byIMD 14 in the form of pulses may define a voltage or current pulseamplitude, a pulse width, and a pulse rate, for stimulation pulsesdelivered by IMD 14 according to that program. The program may alsodefine an electrode combination for delivery of the stimulation pulse,including electrode polarities. Moreover, therapy may be deliveredaccording to multiple programs, wherein multiple programs are containedwithin each of a multiple of groups.

A user, such as a clinician or patient 12, may interact with a userinterface of external programmer 20 to program IMD 14. The userinterface may include an output device for presentation of information,and an input device to receive user input. Programming of IMD 14 mayrefer generally to the generation and transfer of commands, programs, orother information to control the operation of IMD 14. For example,external programmer 20 may transmit programs, parameter adjustments,program selections, group selections, or other information to controlthe operation of IMD 14, e.g., by wireless telemetry. As one example,external programmer 20 may transmit parameter adjustments to supporttherapy changes due to posture changes by patient 12. As anotherexample, a user may select programs or program groups. Again, a programmay be characterized by an electrode combination, electrode polarities,voltage or current amplitude, pulse width, pulse rate, and/or duration.A program group may be characterized by multiple programs that aredelivered simultaneously or on an interleaved or rotating basis.

During the delivery of stimulation therapy, patient 12 may make patienttherapy adjustments, i.e., patient adjustments to one or more parametersof a therapy via an input device of a user interface of a programmer, tocustomize the therapy. In examples where IMD 14 is in a record mode tostore all patient therapy adjustments associated with a specific patientstate, IMD 14 may implement a method to ensure that patient therapyadjustments are associated with the correct patient state intended bypatient 12 when the therapy adjustment was made. The patient 12 mayoccupy the patient state multiple times such that there are multipleinstances of the sensed patient state. A patient state may be a postureor activity level, for example. In some examples, each time the patient12 occupies a posture state, the patient may enter one or more therapyadjustments.

In some cases, external programmer 20 may be characterized as aphysician or clinician programmer if it is primarily intended for use bya physician or clinician. In other cases, external programmer 20 may becharacterized as a patient programmer if it is primarily intended foruse by a patient, e.g., for entry of patient input to specify patientadjustments to one or more therapy parameters. A patient programmer isgenerally accessible to patient 12 and, in many cases, may be a portabledevice that may accompany the patient throughout the patient's dailyroutine. In general, a physician or clinician programmer may supportselection and generation of programs by a clinician for use bystimulator 14, whereas a patient programmer may support adjustment andselection of such programs by a patient during ordinary use, eithermanually or via other user input media.

IMD 14 may be constructed with a biocompatible housing, such as titaniumor stainless steel, or a polymeric material such as silicone orpolyurethane, and surgically implanted at a site in patient 12 near thepelvis. IMB 14 may also be implanted in patient 12 at a locationminimally noticeable to patient 12. Alternatively, IMD 14 may beexternal with percutaneously implanted leads. For SCS, IMD 14 may belocated in the lower abdomen, lower back, upper buttocks, or otherlocation to secure IMB 14. Leads 16 may be tunneled from IMD 14 throughtissue to reach the target tissue adjacent to spinal cord 18 forstimulation delivery.

At the distal ends of leads 16 are one or more electrodes that transferthe electrical stimulation from the lead to the tissue. The electrodesmay be electrode pads on a paddle lead, circular (e.g., ring) electrodessurrounding the body of leads 16, conformable electrodes, cuffelectrodes, segmented electrodes (e.g., partial ring electrodes locatedat different circumferential positions around the perimeter of thelead), or any other type of electrodes capable of forming unipolar,bipolar or multipolar electrode configurations for therapy. Theelectrodes may pierce or affix directly to the tissue itself. Ingeneral, ring electrodes arranged at different axial positions at thedistal ends of leads 16 will be described for purposes of illustration.

In accordance with the techniques of the disclosure, IMD 14 determinesdistances between electrodes disposed on leads 16. In one example, IMB14 senses an impedance between pairs of electrodes disposed on leads 16.IMB 14 determines, based on the sensed impedances, a type of a tissueinterposed between each of the pairs of electrodes disposed on leads 16.Further, IMD 14 determines, based on the type of the tissue, a tissueconductivity of the tissue interposed between each of the pairs ofelectrodes disposed on leads 16.

IMD 14 delivers, via a first electrode, electrical stimulation definedby at least one parameter. In some examples, the parameter is a voltageamplitude. IMB 14 senses, via each of the other electrodes, values ofthe parameter of the delivered electrical stimulation. IMD 14determines, based on the sensed values of the parameter and the valuesof the tissue conductivity of the tissues interposed between theelectrodes, a distance of the first electrode to each of the otherelectrodes. In some examples, IMD 14 may repeat the foregoing processfor each electrode of disposed on leads 16 to determine a distance ofeach electrode to each other electrode.

In some examples, IMD 14 selects, based on the distance of the firstelectrode to each of the other electrodes, one or more electrodes anddelivers electrical stimulation therapy via the selected one or moreelectrodes. In some examples, IMD 14 selects, based on the distance ofthe first electrode to each of the other electrodes, one or moreelectrodes and senses a biosignal of patient 12 via the selected one ormore electrodes. In this fashion, IMD 14 may select electrodes fordelivery of stimulation or sensing a biosignal that are located in adesired tissue of a patient, e.g., nervous tissue. Furthermore, IMB 14may avoid the use of electrodes for delivery of stimulation or sensing abiosignal that are located next to undesirable tissue, such as a bonetissue of the patient, which may interfere with the delivery ofelectrical stimulation therapy or cause erroneous measurements orartifacts during sensing. In some examples, IMD 14 outputs, for displayto a user via a display device of external programmer 20, arepresentation of the plurality of electrodes depicting the distance ofthe first electrode to each of the other electrodes disposed on leads16.

In one example, IMD 14 senses an impedance (or measures an impedancebased on a sensed voltage drop) between pairs of electrodes disposed onleads 16. IMD 14 determines, based on the sensed impedances, a type of atissue interposed between each of the pairs of electrodes disposed onleads 16. IMD 14 may use the tissue conductivity of the tissueinterposed between the first electrode and each of the other electrodesas well as the respective electrical signals indicative of theelectrical stimulus to determine the spatial relationship of the firstelectrode to each of the other electrodes.

In the aforementioned example, IMD 14 determines distances betweenelectrodes disposed on leads 16. However, in other examples, otherdevices, such as external programmer 20, may receive, via telemetriccommunications from IMB 14, measurements sensed by IMD 14 and use suchinformation to determines the distances between electrodes disposed onleads 16. Such devices, such as external programmer 20, may, e.g.,select, based on the distance of the first electrode to each of theother electrodes, one or more electrodes and control IMD 14 to deliverelectrical stimulation therapy or sense a biosignal of patient 12 viathe selected one or more electrodes. In some examples, externalprogrammer 20 may output, for display to a user, a representation of theplurality of electrodes depicting the distance of the first electrode toeach of the other electrodes disposed on leads 16.

The methods, devices, systems, and techniques of the disclosure mayprovide specific improvements to the field of electrical stimulationtherapy that have practical applications. For example, the techniquesdescribed herein may enable a medical device, such as IMD 14, toaccurately measure distances between electrodes disposed on differentleads implanted within a patient. IMD 14, or a user, may utilize thesedistances to determine appropriate electrode combinations or otherparameter values (e.g., amplitude or pulse width) that define electricalstimulation deliverable to the patient. Furthermore, the techniquesdescribed herein may enable a medical device, such as IMD 14 or externalprogrammer 20, to generate a representation of the position of theelectrodes relative to one another for display to a clinician. Such arepresentation may depict a position of each of the plurality ofelectrodes relative to one another with a high degree of accuracy. Thisinformation may be helpful for identifying non-parallel leads or leadsthat have shifted axially within the patient, for example. By accuratelyidentifying the distances between multiple electrodes of leads, thetechniques described herein may enable a clinician and/or a medicaldevice to select electrodes suited for delivery of efficaciouselectrical stimulation therapy or sensing of biosignals from thepatient, thereby increasing the efficacy of electrical stimulationtherapy and/or decreasing the risk of side effects of the electricalstimulation therapy. Further, the techniques of the disclosure mayenable the identification of anatomical structures within tissues of thepatient, such as soft tissue structures within the patient.

FIG. 2 is a functional block diagram illustrating various components ofan IMD 14. In the example of FIG. 2 , IMD 14 includes a housing 85,processing circuitry 80, memory 82, switch circuitry 83, stimulationgeneration circuitry 84, telemetry circuit 88, power source 90, andsensing circuitry 92. The stimulation generation circuitry 84 may form atherapy delivery module. Processing circuitry 83 may control switchcircuitry 83 which switches signals to and/or from leads 16 to sensingcircuitry 92 and/or stimulation generation circuitry 84. Memory 82 maystore instructions for execution by processing circuitry 80, stimulationtherapy data, evoked compound action potential (ECAP) characteristicvalues, posture state information, posture state indications, and anyother information regarding therapy or patient 12. Therapy informationmay be recorded for long-term storage and retrieval by a user, and thetherapy information may include any data created by or stored in IMD 14.Memory 82 may include separate memories for storing instructionsincluding instructions for ECAP analysis, posture state information,therapy adjustment information, prior detected ECAP signals and/orcharacteristic values of ECAPs, program histories, and any otherpertinent data or instructions.

Processing circuitry 80 controls stimulation generation circuitry 84 todeliver electrical stimulation via electrode combinations formed byelectrodes in one or more electrode arrays. For example, stimulationgeneration circuitry 84 may deliver electrical stimulation therapy viaelectrodes (e.g., electrodes 94A-94D and 96A-86D of respective leads 16Aand 16B) on one or more leads 16, e.g., as stimulation pulses orcontinuous waveforms. Components described as processing circuitrywithin IMD 14, external programmer 20 or any other device described inthis disclosure may each comprise one or more processors, such as one ormore microprocessors, digital signal processors (DSPs), applicationspecific integrated circuits (ASICs), field programmable gate arrays(FPGAs), programmable logic circuitry, or the like, either alone or inany suitable combination.

Stimulation generation circuitry 84 may include stimulation generationcircuitry to generate stimulation or a stimulus (in the form of pulsesor waveforms) and switching circuitry to switch the stimulation acrossdifferent electrode combinations, e.g., in response to control byprocessing circuitry 80. In particular, processing circuitry 80 maycontrol the switching circuitry on a selective basis to causestimulation generation circuitry 84 to deliver electrical stimulation toselected electrode combinations and to shift the electrical stimulationto different electrode combinations in a first direction or a seconddirection when the therapy must be delivered to a different locationwithin patient 12. In other examples, stimulation generation circuitry84 may include multiple current sources and sinks to drive more than oneelectrode combination at one time. For example, each electrode may haveits own current source and current sink, which can be selectivelyactivated so that the electrode can source or sink controlled amounts ofcurrent. An electrode configuration, e.g., electrode combination andassociated electrode polarities, may be represented by a data stored ina memory location, e.g., in memory 82, of IMD 14. Processing circuitry80 may access the memory location to determine the electrode combinationand control stimulation generation circuitry 84 to deliver electricalstimulation via the indicated electrode combination. To adjust electrodecombinations, amplitudes, pulse rates, or pulse widths, processingcircuitry 80 may command stimulation generation circuitry 84 to make theappropriate changes to therapy according to instructions within memory82 and rewrite the memory location to indicate the changed therapy. Inother examples, rather than rewriting a single memory location,processing circuitry 80 may make use of two or more memory locations.

When activating stimulation, processing circuitry 80 may access not onlythe memory location specifying the electrode combination but also othermemory locations specifying various stimulation parameters such asvoltage or current amplitude, pulse width and pulse rate. Stimulationgeneration circuitry 84, e.g., under control of processing circuitry 80,then makes use of the electrode combination and parameters informulating and delivering the electrical stimulation to patient 12.

Processing circuitry 80 accesses stimulation parameters in memory 82,e.g., as programs and groups of programs. Upon selection of a particularprogram group, processing circuitry 80 may control stimulationgeneration circuitry 84 to deliver stimulation according to the programsin the groups, e.g., simultaneously or on a time-interleaved basis. Agroup may include a single program or multiple programs. As mentionedpreviously, each program may specify a set of stimulation parameters,such as amplitude, pulse width and pulse rate. In addition, each programmay specify a particular electrode combination for delivery ofstimulation. Again, the electrode combination may specify particularelectrodes in a single array or multiple arrays, e.g., on a single leador among multiple leads. Processing circuitry 80 also may controltelemetry circuit 88 to send and receive information to and fromexternal programmer 20. For example, telemetry circuit 88 may sendinformation to and receive information from programmer 20.

In addition, IMB 14 may store patient 12 input regarding perceivedphysiological conditions (e.g., symptoms) not detectable by anyimplemented sensors. For example, patient 12 may provide input toprogrammer 20 that indicates where the patient perceives any symptomsand characteristics of that particular type of symptom. processingcircuitry 80 may associate this physiological condition information withthe currently detected posture state, the stimulation parameters, and/ora time stamp to provide a complete therapy picture to the patient orclinician at a later time. Such information may be stored in memory 82of IMD 14, the memory of programmer 20, and/or the memory of some otherdevice.

Wireless telemetry in IMD 14 with external programmer 20, e.g., apatient programmer or a clinician programmer, or another device may beaccomplished by radio frequency (RF) communication or proximal inductiveinteraction of IMD 14 with external programmer 20. Telemetry circuit 88may send information to and receive information from external programmer20 on a continuous basis, at periodic intervals, at non-periodicintervals, or upon request from the stimulator or programmer. To supportRF communication, telemetry circuit 88 may include appropriateelectronic components, such as amplifiers, filters, mixers, encoders,decoders, and the like.

Power source 90 delivers operating power to the components of IMD 14.Power source 90 may include a small rechargeable or non-rechargeablebattery and a power generation circuit to produce the operating power.Recharging may be accomplished through proximal inductive interactionbetween an external charger and an inductive charging coil within IMD14. In some embodiments, power requirements may be small enough to allowIMD 14 to utilize patient motion and implement a kineticenergy-scavenging device to trickle charge a rechargeable battery. Inother embodiments, traditional batteries may be used for a limitedperiod of time. As a further alternative, an external inductive powersupply could transcutaneously power IMD 14 when needed or desired.

Sensing circuitry 92 may be configured to detect signals from a tissueof the patient. In other examples, sensing circuitry 92 may be locatedon lead 16, and may include for, example, one or more of the electrodesin leads 16 in combination with suitable amplification, filtering and/orsignal processing circuitry. In some examples, sensing circuitry 92 mayinclude an additional electrode on housing 85 of IMD 14. In someexamples, Sensing circuitry 92 may be carried by an additional sensorlead positioned somewhere within patient 12, provided as an independentimplantable sensor, or even worn on patient 12.

Processing circuitry 80 may be configured to control stimulationgeneration circuitry 84 to deliver an electrical stimulus via a firstelectrode 94. Processing circuitry 80 controls sensing circuitry 92 tosense, via each of the other electrodes 94, respective electricalsignals indicative of the electrical stimulus. In some examples, theelectrical signals are indicative of the voltage amplitude at each ofthe other electrodes 94. For example, processing circuitry 84 controlsstimulation generation circuitry 84 to deliver, via electrode 94A, anelectrical stimulus defined by a first voltage amplitude. Processingcircuitry 84 senses, via sensing circuitry 92 and at each of electrodes94B, 94C, 94D, and 96A-96D, respective electrical signals indicative ofthe electrical stimulus, e.g., a voltage amplitude at each of electrodes94B, 94C, 94D, and 96A-96D resulting from delivery of the electricalstimulus at electrode 94A.

Processing circuitry 84 determines, based on the respective sensedelectrical signals indicative of the electrical stimulus, a distance ofelectrode 94A to each of the other electrodes 94, 96. For example,processing circuitry 84 determines a difference between the voltagedelivered at electrode 94A and a sensed voltage at, e.g., electrode 96A.In some examples, processing circuitry 84 uses a tissue conductivitybetween electrodes 94A, 96A (calculated as described below) to convertthe difference between the voltage amplitude of the electrical stimulusdelivered at electrode 94A and the sensed voltage amplitude at electrode96A (e.g., the voltage drop between electrodes 94A and 96A) into aspatial relationship. Processing circuitry 84 may repeat the foregoingprocess for each electrode of disposed on leads 16 to determine, e.g., aspatial relationship of each electrode of disposed on leads 16 to eachother lead disposed on leads 16 to determine, e.g., a distance of eachelectrode 94, 96 to each other electrode 94, 96. For example, by knowingthe voltage amplitude of an electrical stimulus delivered at electrode94A, the area of electrodes 94 on lead 16A and electrodes 96 on lead16B, a tissue conductivity of a tissue interposed between electrode 94Aand electrode 96A, a tissue impedance of the tissue interposed betweenelectrode 94A and electrode 96A, and a voltage amplitude sensed atelectrode 96A, processing circuitry 84 may apply geometric andtrigonometric operations to determine a spatial relationship betweenelectrodes 94A and 96A, such as a scalar distance, a vector, or anorientation, etc. In some examples where only the distance betweenelectrode 94A and electrode 96A is desired, the voltage amplitude sensedat, e.g., electrode 94B and/or the spacing of electrodes on lead 16A maynot be needed.

Processing circuitry 84 uses the calculated distances of each electrode94, 96 to each other electrode 94, 96 to, e.g., select one or moreelectrodes 94, 96 for subsequent delivery of electrical stimulation orfor sensing a biosignal of patient 12. In some examples, processingcircuitry 84 uses the calculated distances of each electrode 94, 96 toeach other electrode 94, 96 to adjust one or more electrical stimulationparameters for subsequent delivery of electrical stimulation anddelivers electrical stimulation in accordance with the adjusted one ormore parameters. For example, processing circuitry 84 may use thecalculated distances of each electrode 94, 96 to each other electrode94, 96 to increase a value of an electrical stimulation parameter (e.g.,a current or voltage amplitude) for electrodes 94, 96 further from atarget tissue of the patient and decrease a value of the electricalstimulation parameter (e.g., a current or voltage amplitude) forelectrodes 94, 96 closer to the target tissue of the patient. Further,processing circuitry 84 may adjust the value of the electricalstimulation parameter of each other electrode 94, 96 in proportion to adistance of each other electrode 94, 96 to the target tissue of thepatient with respect to a distance of the first electrode 94A to thetarget tissue.

In some examples, processing circuitry 84 outputs, via telemetrycircuitry 88, the calculated distances of each electrode 94, 96 to eachother electrode 94, 96 to external programmer 20. As described in moredetail below, external programmer 20 may generate a 2-dimensional or3-dimensional (3D) representation of the calculated distances of eachelectrode 94, 96 to each other electrode 94, 96 for display to a user.

In some examples, processing circuitry 80 determines an impedancebetween electrodes 94, 96. For example, processing circuitry 80 maydetermine an impedance between various combinations or pairs ofelectrodes 94, 96 and/or housing 85 of IMD 14. For example, processingcircuitry 80 may control stimulation generation circuitry 84 to delivera stimulus (e.g., at a known voltage and current) via a first electrodeof electrodes 94 and sense, via sensing circuitry 92, a resultant signalvia a second electrode of electrodes 94. By delivering a stimulus with aknown voltage and/or current and determining a value of the signalsensed by another electrode, processing circuitry 80 may compute theimpedance of a material (e.g., a tissue) between a pair of electrodes inaccordance with the following equation:

${{{Impendance}{}Z} = \frac{{Voltage}{}V}{{Current}I}},$${{Conductance}G} = \frac{1}{{Impedance}Z}$

Processing circuitry 80 can then determine, based on the sensedimpedances, a type of a tissue interposed between each of the pairs ofelectrodes 94, 96 and/or housing 85 of IMD 14. For example, memory 82may store, e.g., as a look-up table, a plurality of tissue types 202, acorresponding tissue impedance 204 for each of the plurality of tissuetypes 202, and a corresponding tissue conductivity 206 for each of theplurality of tissue types 202. For example, tissue types 202 may includea nerve tissue, a bone tissue, a connective tissue, or an adiposetissue, and memory 82 may store, e.g., a tissue impedance 204 and atissue conductivity 206 for each of the nerve tissue, the bone tissue,the connective tissue, or the adipose tissue.

Processing circuitry 80 compares, for each pair of electrodes 94, 96and/or housing 85 of IMD 14, a value of the sensed impedance to a valueof the tissue impedance 204 of each tissue type 202. In response todetermining that the value of the sensed impedance of the pair ofelectrodes 94, 96 and/or housing 85 of IMD 14 matches a value of atissue impedance 204, processing circuitry 80 determines that the tissueinterposed between the pair of electrodes 94, 96 and/or housing 85 ofIMD 14 is a tissue type corresponding to the matching tissue type 202.Thus, in this manner, processing circuitry 84 determines, based on thesensed impedances, a type of a tissue interposed between each of thepairs of electrodes 94, 96 and/or housing 85 of IMD 14. Further,processing circuitry 84 determines, based on the type of the tissue, atissue conductivity of the tissue interposed between each of the pairsof electrodes disposed on leads 16. For example, processing circuitry 84retrieves, based on the tissue type 202, a corresponding tissueconductivity 206. Processing circuitry 84 uses the tissue conductivity206 between two electrodes 94, 96 to convert a difference between avoltage amplitude of the electrical stimulus delivered at a firstelectrode 94, 96 and the sensed voltage amplitude at a second electrode94, 96 into the spatial relationship between the pair of electrodes 94,96.

The conductivity for different tissues between electrodes can bedetermined and used as described herein to identify the spacing ofelectrodes. For example, the cell constant K is a ratio of a distance dbetween a pair of electrodes 94, 96 to an effective area a of theelectrodes 94, 96, as defined below:

$K = \frac{d}{a}$

Processing circuitry 80 may compute a conductivity σ using theconductance G and the cell constant K calculated above, whereinconductivity σ=conductance G×cell constant K. From the previousequations the following relationship is defined:

${{conductivity}\sigma} = {\left( \frac{1}{{Impedance}Z} \right)\left( \frac{{Distance}d{between}a{pair}{of}{electrodes}}{{Effective}{area}a{of}{the}{electrodes}} \right)}$

Using the known value of the electrode area a, a value of impedance Imeasured by processing circuitry 80, and a value of conductivity σretrieved from memory 82, the above equation can be rearranged to enableprocessing circuitry 80 to solve for an unknown value of distance dbetween a pair of electrodes 94, 96:

distance d=(conductivity σ) (effective area a of the electrodes)(Impedance I) The above relationship may also be stated in terms ofvoltage and current:

$\sigma = {{G \times K} = {{\left( \frac{1}{Z} \right)\left( \frac{d}{a} \right)} = {\left( \frac{I}{V} \right)\left( \frac{d}{a} \right)}}}$$d = \frac{\sigma \times a \times V}{I}$

In some examples, IMD 14 may include additional circuitry (not depictedin FIG. 2 ) for measuring conductivity σ of the tissue interposedbetween the pair of electrodes 94, 96. In some examples, if distance dbetween a pair of electrodes 94, 96 (such as, for example, electrodes94A and 94B affixed at a known separation distance on lead 16A), thenprocessing circuitry 80 may instead calculate conductivity of the tissueinterposed between the electrodes 94, 96.

FIG. 3 is a functional block diagram illustrating various components ofan external programmer 20 for IMD 14. As shown in FIG. 3 , externalprogrammer 20 is an external device that includes processing circuitry104, memory 108, telemetry circuit 110, user interface 106, and powersource 112. External programmer 20 may be embodied as a patientprogrammer or a clinician programmer.

A clinician or patient 12 interacts with user interface 106 in order tomanually change the stimulation parameters of a program, change programswithin a group, turn electrical stimulation ON or OFF, view therapyinformation, view patient state information, view a posture stateindication, or otherwise communicate with IMD 14. Processing circuitry104 controls user interface 106, retrieves data from memory 108 andstores data within memory 108. Processing circuitry 104 also controlsthe transmission of data through telemetry circuit 110 to IMDs 14 or 26.Memory 108 includes operation instructions for processing circuitry 104and data related to patient 12 therapy.

User interface 106 may comprise one or more input devices and one ormore output devices. The input devices of user interface 106 may includea communication device such as a keyboard, pointing device, voiceresponsive system, video camera, biometric detection/response system,button, sensor, control pad, microphone, presence-sensitive screen, orany other type of device for detecting input from the user.

The output devices of user interface 106 may include a communicationunit such as a display, sound card, video graphics adapter card,speaker, presence-sensitive screen, one or more USB interfaces, videoand/or audio output interfaces, or any other type of device capable ofgenerating tactile, audio, video, or other output. The output devices ofuser interface 106 may include a display device 114, which may functionas an output device using technologies including liquid crystal displays(LCD), quantum dot display, dot matrix displays, light emitting diode(LED) displays, organic light-emitting diode (OLED) displays, cathoderay tube (CRT) displays, e-ink, or monochrome, color, or any other typeof display capable of generating tactile, audio, and/or visual output.In other examples, the output devices of user interface 106 may producean output to a user in another fashion, such as via a sound card, videographics adapter card, speaker, presence-sensitive screen, one or moreUSB interfaces, video and/or audio output interfaces, or any other typeof device capable of generating tactile, audio, video, or other output.In some examples, the output devices of user interface 106 may include apresence-sensitive display that may serve as a user interface devicethat operates both as one or more input devices and one or more outputdevices.

Telemetry circuit 110 allows the transfer of data to and from IMB 14.Telemetry circuit 110 may communicate automatically with IMD 14 inreal-time, at a scheduled time, or when the telemetry circuit detectsthe proximity of the stimulator. User interface 106 may then updatedisplayed information accordingly. Alternatively, telemetry circuit 110may communicate with IMB 14 when signaled by a user through userinterface 106. To support RF communication, telemetry circuit 110 mayinclude appropriate electronic components, such as amplifiers, filters,mixers, encoders, decoders, and the like. Power source 112 may be arechargeable battery, such as a lithium ion or nickel metal hydridebattery. Other rechargeable or conventional batteries may also be used.In some cases, external programmer 20 may be used when coupled to analternating current (AC) outlet, i.e., AC line power, either directly orvia an AC/DC adapter.

In some examples, external programmer 20 may be configured to rechargeIMD 14 in addition to programming IMD 14. Alternatively, a rechargingdevice may be capable of communication with IMD 14. Then, the rechargingdevice may be able to transfer programming information, data, or anyother information described herein to IMD 14. In this manner, therecharging device may be able to act as an intermediary communicationdevice between external programmer 20 and IMB 14. In other cases, theprogrammer may be integrated with a recharging functionality in thecombined programming/recharging device. The techniques described hereinmay be communicated between IMD 14 via any type of external devicecapable of communication with IMD 14.

In some examples, processing circuitry 104 receives, via telemetrycircuit 110, measurements sensed by IMD 14 and uses such information todetermines spatial relationships between electrodes 94, 96 disposed onleads 16 in the manner described above. Further, processing circuitry104 may select, based on the spatial relationships of the firstelectrode to each of the other electrodes, one or more electrodes 94, 96and control IMB 14 to deliver electrical stimulation therapy or sense abiosignal of patient 12 via the selected one or more electrodes 94, 96.

In some examples, processing circuitry 104 generates a representation ofthe plurality of electrodes 94, 96 disposed on leads 16 that depicts thespatial relationships of each electrode 94, 96 to each of the otherelectrodes 94, 96. In some examples, the representation of electrodes94, 96 depicts a 2D or 3D spatial relationship of lead 16A to 16B and/ora 3D spatial relationship of electrodes 94, 96 to one another. Such arepresentation may depict, e.g., a distance of each electrode 94, 96 toeach of the other electrodes 94, 96. In other examples, processingcircuitry 104 may control user interface 106 to present numericaldistances alone, or in addition to graphical depiction of the spatialrelationships between electrodes.

In some examples, processing circuitry 104 generates a representationthat comprises a 3D model the plurality of electrodes 94, 96 disposed onleads 16. Using the calculated distances of each electrode 94, 96 toeach of the other electrodes 94, 96, processing circuitry 104 mayadjust, warp, stretch, or skew the shape or position of an normallystraight lead 16A, lead 16B, and each electrode 94, 96 disposed on leads16 to more accurately depict a true location of electrodes 94, 96 andleads 16 within the body of patient 12. In this manner, user interface106 may be controlled by processing circuitry 104 to present leads inthe shape as implanted within the patient. Processing circuitry 104displays the representation of the plurality of electrodes 94, 96disposed on leads 16 to a user via display 114.

FIG. 4 is a conceptual illustration of example electrodes in accordancewith the techniques of the disclosure. For convenience, FIG. 4 isdescribed with respect to FIGS. 1 and 2 . In the example of FIG. 4 , IMB14 and leads 16 are implanted within patient 14. Lead 16A compriseselectrodes 94A and 94B and lead 16B comprises electrodes 96A and 96B.Electrodes 94A and 96A are implanted within tissue 402A that comprises afirst tissue type (e.g., nerve tissue). Electrodes 94B and 96B areimplanted within tissue 402B that comprises a second tissue type (e.g.,bone tissue).

IMD 14 determines an impedance between electrodes 94, 96. For example,IMD 14 senses an impedance between various combinations or pairs ofelectrodes 94, 96 and/or housing 85 of IMD 14. For example, IMB 14delivers a stimulus (e.g., at a known voltage and current) via electrode94A and senses a resulting first signal via electrode 96A. As anotherexample, IMB 14 delivers a stimulus via electrode 94B and senses aresulting second signal via electrode 96B. In some examples, IMD 14delivers a stimulus via electrode 94A and senses a resulting thirdsignal via housing 85. By delivering a stimulus with a known voltageand/or current and determining a value of the signal sensed by anotherelectrode, IMD 14 may compute the impedance between a pair ofelectrodes. In the foregoing examples, IMD 14 computes a first impedancebetween electrodes 94A and 96A, a second impedance between electrodes94B and 96B, and a third impedance between electrode 94A and housing 85.

IMD 14 determines, based on the sensed impedances, a type of a tissueinterposed between each pair of electrodes 94, 96 and/or housing 85 ofIMD 14. For example, IMB 14 may use the first, second, and third sensedimpedances to look up tissue impedances 204 and corresponding tissuetypes 202 stored in memory 82. For example, IMD 14 determines that thefirst impedance between electrodes 94A and 96A and the third impedancebetween electrode 94A and housing 85 correspond to a tissue impedance ofnerve tissue, and so determines that tissue 402A comprises nerve tissue.Similarly, IMB 14 may determine that the second impedance betweenelectrodes 94B and 96B corresponds to a tissue impedance of bone tissue,and so determines that tissue 402B comprises bone tissue. IMD 14retrieves from memory 82, a tissue conductivity for nerve tissue (e.g.,tissue 402A) and bone tissue (e.g., tissue 402B).

IMD 14 may be configured to deliver an electrical stimulus via a firstelectrode 94, 96 and sense an electrical signal indicative of theelectrical stimulus via a second electrode 94, 96. IMD 14 may use amagnitude of the electrical stimulus, the sensed electrical signalindicative of the electrical stimulus, and a tissue conductivityinterposed between the first and second electrodes 94, 96 to determine adistance 404 between the first and second electrodes 94, 96.

For example, IMB 14 senses between electrode 94A and electrode 96A, avalue of impedance of 2,500 Ohms. By using a tissue conductivity valueof 0.265 Siemens per meter for nerve tissue for tissue 402A and the areaof electrodes 94A and 96A of approximately 12 square millimeters, IMD 14determines that electrodes 94A and 96A are 7.95 millimeters from oneanother. These values may be different for other electrode materials,sizes, or other variations, as indicated in another example below.

As another example, IMB 14 senses between electrode 94B and electrode96B, a value of impedance of 100,000 Ohms. By using a tissueconductivity value of 3.5e-3 Siemens per meter for bone tissue fortissue 402B and area of electrodes 94B and 96B of approximately 12square millimeters, IMD 14 determines that electrodes 94B and 96B are4.2 millimeters from one another.

Processing circuitry 84 may repeat the foregoing process for eachelectrode of disposed on leads 16 to determine, e.g., a distance 404 ofeach electrode 94A, 94B, 96A, 96B to each other electrode 94A, 94B, 96A,96B and housing 85. In some examples, processing circuitry 84 may applya scaling factor to sensed voltages at each of electrodes 94, 96 todetermine the distance between each of electrodes 94, 96. Additionaldescription of the use of such a scaling factor is described below withrespect to FIG. 8 .

FIG. 5 is a flowchart illustrating an operation in accordance with thetechniques of the disclosure. For convenience, FIG. 5 is described withrespect to IMB 14 of FIGS. 1 and 2 . However, portions of the operationof FIG. 5 may be performed by other devices, such as external programmer20 of FIGS. 1 and 3 .

In the example of FIG. 5 , IMB 14 determines an impedance betweenelectrode 94A and a plurality of other electrodes 94, 96 and housing 85(502). For example, IMB 14 delivers a stimulus via electrode 94A andsenses a resulting signal via each of electrodes 94B-94D, 96A-96D, andhousing 85. By delivering a stimulus with a known voltage and/or currentand determining a value of the signal sensed by another electrode, IMD14 determines the impedance between electrode 94A and each of theplurality of other electrodes 94, 96 and housing 85.

IMD 14 can then determine, based on the sensed impedances, a type oftissue interposed between electrode 94A and each of the plurality ofother electrodes 94, 96 and housing 85 (504). For example, memory 82 ofIMD 14 may store, e.g., as a look-up table, a plurality of tissue types202, a corresponding tissue impedance 204 for each of the plurality oftissue types 202, and a corresponding tissue conductivity 206 for eachof the plurality of tissue types 202. For example, tissue types 202 mayinclude a nerve tissue, a bone tissue, a connective tissue, or anadipose tissue, and memory 82 may store, e.g., a tissue impedance 204and a tissue conductivity 206 for each of the nerve tissue, the bonetissue, the connective tissue, or the adipose tissue.

IMD 14 may then compare, for each pair comprising electrode 94A and oneof electrodes 94, 96 and housing 85, a value of the sensed impedance toa value of the tissue impedance 204 of each tissue type 202. In responseto determining that the value of the sensed impedance of the pairmatches a value of a tissue impedance 204, IMB 14 determines that thetissue interposed between the pair is a tissue type corresponding to thematching tissue type 202 stored in memory 82. Thus, in this manner, IMD14 determines, based on the sensed impedances, a type of a tissueinterposed between electrode 94A and each of the plurality of otherelectrodes 94, 96 and housing 85. Further, IMD 14 determines, based onthe type of the tissue, a tissue conductivity of the tissue interposedbetween electrode 94A and each of the plurality of other electrodes 94,96 and housing 85 (506). For example, processing circuitry 84 retrieves,based on the tissue type 202, a corresponding tissue conductivity 206.In other examples, IMD 14 may obtain an estimated or assumed tissueconductivity to be used in the process to follow instead of measuringactual conductivity as described in steps 502, 504, and 506.

IMD 14 may be configured to deliver an electrical stimulus via electrode94A according to at least one parameter (508). Further, IMB 14 senses,via each of the plurality of other electrodes 94, 96 and housing 85,respective electrical signals indicative of the electrical stimulus(510). In some examples, the parameter is a voltage amplitude. Forexample, IMD 14 delivers, via electrode 94A, an electrical stimulusaccording to a first voltage amplitude. IMD 14 senses, at each of theplurality of other electrodes 94, 96 and housing 85, respectiveelectrical signals indicative of the electrical stimulus, e.g., a valueof a voltage amplitude resulting from delivery of the electricalstimulus at electrode 94A.

IMD 14 determines, based on the respective electrical signals indicativeof the electrical stimulus and the tissue conductivity 206 of thetissues interposed between electrode 94A and each of the plurality ofother electrodes 94, 96 and housing 85, a spatial relationship ofelectrode 94A to each other electrode (512). For example, IMB 14determines a difference between a value of the voltage amplitude of theelectrical stimulus delivered at electrode 94A and a value of a sensedvoltage amplitude at, e.g., electrode 96A. IMD 14 uses a tissueconductivity of the tissue interposed between electrodes 94A, 96A toconvert the difference between the voltage amplitude of the electricalstimulus delivered at electrode 94A and the sensed value of the voltageamplitude at electrode 96A (e.g., the voltage drop between electrodes94A and 96A) into a spatial relationship, such as a distance. IMD 14 mayrepeat the foregoing process between electrode 94A and each of theplurality of other electrodes 94, 96 and housing 85 to determine, e.g.,a spatial relationship of electrode 94A to electrode 94A and each of theplurality of other electrodes 94, 96 and housing 85.

IMD 14 and/or external programmer 20 performs an action based on thecalculated spatial relationships of electrode 94A to electrode 94A andeach of the plurality of other electrodes 94, 96 and housing 85 (514).For example, IMB 14 uses the calculated spatial relationships betweenelectrode 94A and each of the plurality of other electrodes 94, 96 andhousing 85 to, e.g., select one or more electrodes 94, 96 for subsequentdelivery of electrical stimulation and deliver electrical stimulationvia the selected one or more electrodes 94, 96. As another example, IMB14 uses the calculated spatial relationships between electrode 94A andeach of the plurality of other electrodes 94, 96 and housing 85 to,e.g., adjust one or more electrical stimulation parameters forsubsequent delivery of electrical stimulation and deliver electricalstimulation in accordance with the adjusted one or more parameters. Asanother example, IMB 14 uses the calculated spatial relationshipsbetween electrode 94A and each of the plurality of other electrodes 94,96 and housing 85 to, e.g., select one or more electrodes 94, 96 forsubsequent sensing of a biosignal of patient 12 and senses the biosignalof patient 12. As another example, IMD 14 outputs, to externalprogrammer 20, the calculated spatial relationships of each electrode94, 96 to each other electrode 94, 96 to external programmer 20.External programmer 20 may generate a representation of the calculatedspatial relationships of each electrode 94, 96 to each other electrode94, 96 in 2 or 3 dimensions and output the representation of the spatialrelationships for display to a user. In another example, IMD 14 mayscale user inputs for stimulation parameter values according to thespatial relationships between electrodes. The user may be expecting thatthe leads are parallel to each other and select amplitudes or pulsewidths, for example, accordingly. Instead of showing the user how theelectrode distances vary, IMD 14 may instead scale the user or systemselected parameter values to account for the differences in distancesbetween electrodes. For instance, IMD 14 may reduce current amplitudevalues for electrodes closer together than expected and increase currentamplitude values for electrodes further apart than expected. Theexternal programmer (e.g., programmer 20) may present an indication thatsuch corrections to parameter values are being made.

FIG. 6 is an illustration depicting an example user interface 602 ofexternal programmer 20 of FIG. 3 . In some examples, user interface 600is an example of user interface 106 of external programmer 600 of FIG. 3. User interface 600 may be used to display spatial relationshipsbetween electrodes 94, 96 of leads 16 as described above. FIG. 6 depictsdisplay window 602 of user interface 600, which is displaying examplelead icons 616A and 616B (collectively, “lead icons 616”), which maycorrespond to leads 16A and 16B, respectively, of IMD 14.

In the example of FIG. 6 , lead icon 616A includes four electrode icons696A-696D (collectively, “electrode icons 694”) and lead icon 616Bincludes four electrode icons 696A-696D (collectively, “electrode icons696”). Electrode icons 694 may correspond to electrodes 94 of IMD 14 andelectrode icons 696 may correspond to electrodes 96 of IMD 14.

Lead icons 616 may have more, or fewer, electrode icons 694, 696,depending on the particular lead configuration in use, and other numbersof lead icons 616 may be displayed on screen 602. For ease ofillustration, only four electrode icons 694, 696 (or a portion of fourelectrodes) are depicted on each of lead icons 616. In addition, window602 may depict stimulation zones, electrical field zones, activationzones, etc. (not shown), that correspond to the stimulation deliverableby various electrode combinations. In addition, or alternatively, userinterface 600 may present lead icons 616 with respect to one or moreanatomical structures of the patient, such as a spinal cord, vertebrae,epidural space, skin, etc. Any of the devices described herein mayutilize the calculated impedances, voltages, or other characteristics ofsensed electrical signals to determine distances from the electrodes toanatomical regions and place each lead icons 616 at an appropriatedistance from such structures.

As described above, external programmer 20 may be configured to generatea representation that depicts the spatial relationships of eachelectrode 94, 96 to each of the other electrodes 94, 96, viacorresponding electrode icons 694, 696. In some examples, lead icons 616depict a 2D or 3D spatial relationship of lead 16A to 16B and/orelectrode icons 694, 696 depict a 2D or 3D spatial relationship of eachof electrodes 94, 96 to each other electrode 94, 96. For example,electrode icons 694, 696 depict a distance of each of electrodes 94, 96to each other electrode 94, 96.

In some examples, lead icons 616 and electrode icons 694, 696 comprise a3D model of leads 16 and electrodes 94, 96 of IMD 20. Externalprogrammer 20 uses the determined spatial relationships of each ofelectrodes 94, 96 to each other electrode 94, 96 to adjust, warp,stretch, or skew the shape or position of lead icons 616 and electrodeicons 694, 696 to more accurately depict a true location of electrodes94, 96 and leads 16 within the body of patient 12. For example, asdepicted in FIG. 6 , external programmer 20 adjusts lead icon 616A andlead icon 616B relative to lead icon 616A to more accurately depict atrue location of electrodes 94, 96 and leads 16 within the body ofpatient 12.

FIGS. 7A-7B are conceptual illustrations of example electrodes 94, 96and distances between each electrode in accordance with the techniquesof the disclosure. For convenience, FIGS. 7A and 7B are described withrespect to IMB 14 of FIG. 2 . As depicted in the example of FIG. 7A,electrode 94A is located at a position D comprising planar coordinates(D_(X), D_(Y), D_(Z)), electrode 96A is located at a position E0comprising planar coordinates (E0_(X), E0_(Y), E0_(Z)), electrode 96B islocated at a position E1 comprising planar coordinates (E1_(X), E1^(Y),E1_(Z)), and electrode 96C is located at a position E2 comprising planarcoordinates (E2_(X), E2_(Y), E2_(Z)).

As depicted in FIGS. 7A-7B, processing circuitry 80 back-calculates arelative location of electrodes 94A, 96A, 96B, and 96C to one anotherusing spatial relationships determined in the manner described above.For example, if all the locations of electrodes 94, 96 and IMB 14 areknown, processing circuitry 80 may calculate a relative coordinate ofeach of electrodes 94, 96 and IMB 14 using the distance equationsdefined above using a process known as trilateration. Trilateration isthe process of determining absolute or relative locations of points bymeasurement of distances, using the geometry of circles, spheres ortriangles.

An example back-calculation algorithm using trilateration is set forthbelow:

$\begin{matrix}{{{E_{1} - E_{0}}} = d_{01}} \\{{{E_{2} - E_{0}}} = d_{02}} \\ \vdots \\{{{E_{2} - D}} = d_{D2}}\end{matrix}$

The objective of the back-calculation algorithm set forth above is tolocalize and obtain a relative position of all points (e.g., electrodes94, 96) using the distances between electrodes 94, 96 determined asdescribed above. For example, using the techniques described above,processing circuitry 80 may determine distances between pairs ofelectrodes 94, 96, but processing circuitry 80 obtains such distances atdifferent, unknown positions. Processing circuitry 80 may formulatethese different distances as an optimization problem, wherein theobjective function to be minimized includes the residuals of thedistance equations, and wherein the variables in the search space arethe coordinates of all the points (e.g., electrodes 94, 96).

Using the back-calculation algorithm set forth above, processingcircuitry 80 may determine relative distances between each of electrodes94A, 96A, 96B, and 96C. For example, as depicted in FIG. 7B, processingcircuitry 80 performs back-calculation to determine that electrodes 94Aand 96A are a distance d_(D0) apart, electrodes 94A and 96B are adistance d_(D1) apart, electrodes 94A and 96C are a distance d_(D2)apart, electrodes 96A and 96B are a distance d₀₁ apart, electrodes 96Aand 96C are a distance doe apart, and electrodes 96B and 96C are adistance d₁₂ apart.

FIG. 8 is a conceptual illustration of example electrodes in accordancewith the techniques of the disclosure. For convenience, FIG. 8 isdescribed with respect to IMD 14 of FIG. 2 . The techniques described inFIG. 8 may be substantially similar to the techniques for trilaterationdescribed in FIGS. 7A-7B above, except that instead of performingtrilateration using positions E0, E1, E2, etc., FIG. 8 provides anexample of trilateration performed with sensed voltage amplitudes V₀,V₁, V₂, etc.

In accordance with the techniques of the disclosure, a medical device,such as IMD 14 of FIG. 1 , senses, via each of a plurality of electrodes94, 96, a respective electrical signal. In some examples, the electricalsignal is an electrical stimulus, as described above. In other examples,the electrical signal is a cardiac signal of a heart of patient 12,stimulation from one or more electrodes 94, etc. IMD 14 determines, foreach electrode 94, 96 of the plurality of electrodes 94, 96, arespective value for each respective electrical signal. Further, IMD 14determines, based on the respective values for each respectiveelectrical signal sensed by each other electrode 94, 96 of the pluralityof electrodes 94, 96, a spatial relationship between each electrode 94,96 of the plurality of electrodes 94, 96 and each other electrode 94, 96of the plurality of electrodes 94, 96. In this fashion, IMD 14 maydetermine relative positions of each electrode 94, 96 to each otherelectrode 94, 96.

IMD 14 may use the sensed electrical signals, such as the sensed cardiacsignals of the heart of patient 12, to provide additional context to IMD14 for use in determining the spatial relationships between eachelectrode. For example, IMD 14 further determines, based on therespective values for each respective electrical signal sensed by eachother electrode 94, 96 of the plurality of electrodes 94, 96, a spatialrelationship between each electrode 94, 96 of the plurality ofelectrodes 94, 96 and the heart of patient 12. In this fashion, IMD 14may determine an absolute position of each electrode 94, 96 to the heartof patient 12.

In practice, spatial relationships determined by IMD 14, such as adistance d that processing circuitry 80 solves from the equationd=σ×a×I, may have noise compared to a true distance. This noise mayarise from a variety of factors. For example, noise may arise due to anaccuracy of the impedance measurement (e.g., the capability of IMD 14 toaccurately measure impedance). Furthermore, noise may arise due to anaccuracy of the conductivity measurement or value stored in memory 82(e.g., the capability of IMD 14 to accurately measure conductivity,variations in tissue properties between patients, days, a localenvironment of electrodes 94, 96, etc.). Additionally, by determiningonly spatial relationships between electrodes 94, 96, processingcircuitry 80 may not determine a unique solution for an absolutelocation of electrodes 94, 96. For example, while processing circuitry80 determines spatial relationships between each of electrodes 94, 96 toone another, such determined spatial relationships may not define anabsolute orientation (e.g., the distances between electrodes 94, 96 maybe maintained for different orientations of electrodes 94, 96). However,a unique solution (e.g., an absolute solution to the location andorientation of electrodes 94, 96) is not necessary to determine whetherrelative movement between electrodes 94, 96 has occurred (e.g., due tolead migration, changes in electrode distance, etc.).

In the context of electrical signals, one may assume that a differencein a sensed signal (e.g., a voltage difference) on each electrode 94, 96in response to a source signal to be an analogue for the distance dbetween the electrode 94, 96 and the origin of the source signal. Asdescribed herein, the source signal is typically an electrical stimulusdelivered via one of electrodes 94, 96. However, in other examples, thesource signal may be, e.g., a cardiac signal sensed from a heart of thepatient, stimulation from one or more electrodes 94, 96 (e.g.,implantable electrodes), one or more electrodes external to the patient,or some other electrical signal that each of electrodes 94, 96 may senseand that varies between the contacts. The use of an electrical stimulus,such as a cardiac signal (or stimulation delivered via electrodesexternal to the patient applied at known anatomical landmarks) mayprovide further context to the spatial relationships of electrodes 94,96 and leads 16 to each other of electrodes 94, 96 and leads 16.Additionally, such electrical stimulus, delivered from a known location(e.g., the heart or external electrodes at known locations) may assistIMD 14 to define spatial relationship between electrodes 94, 96 andleads 16 and the heart of patient 12. Such information may allowprocessing circuitry 80 to determine spatial relationships of electrodes94, 96 and leads 16 relative to an anatomical landmark, such as theheart of the patient, rather than merely a relative spatial relationshipof electrodes 94, 96 and leads 16 to one another.

For example, as depicted in the example of FIG. 8 , electrode 94Adelivers an electrical stimulus comprising a voltage amplitude VD.Electrode 96A senses an electrical signal comprising a voltage amplitudeV₀ resulting from the stimulus, electrode 96B senses an electricalsignal comprising a voltage amplitude V₁ resulting from the stimulus,and electrode 96C senses an electrical signal comprising a voltageamplitude V₂ resulting from the stimulus. Accordingly, a voltagedifference V_(XY) between a first voltage V_(X) and a second voltageV_(Y) (where V_(X) and V_(Y) are the voltages at respective electrodes)may be defined for each electrode 94, 96 as follows:

$\begin{matrix}{{❘{v_{1} - v_{0}}❘} = v_{01}} \\{{❘{v_{2} - v_{0}}❘} = v_{02}} \\ \vdots \\{{❘{v_{2} - v_{D}}❘} = v_{D2}}\end{matrix}$

Accordingly, processing circuitry 80 determines that a voltagedifference Vero exists between electrodes 94A and 96A, a voltagedifference V_(D1) exists between electrodes 94A and 96B, a voltagedifference V_(D2) exists between electrodes 94A and 96C, a voltagedifference V₀₁ exists between electrodes 96A and 96B, a voltagedifference V₀₁ exists between electrodes 96A and 96C, and a voltagedifference V₁₂ exists between electrodes 96B and 96C.

Processing circuitry 80 may use this additional information in the backcalculation algorithm described above to better localize and obtainrelative spatial relationships, as well as to better inform thedetermination of electrode spacing. For example, processing circuitry 80may use this information to determine a relative and/or absoluteposition of all points (e.g., electrodes 94, 96). For example,processing circuitry 80 simultaneously uses both the determined distanced_(XY) and the determined voltage difference V_(XY) for each pair ofelectrodes 94, 96 to scale the electrical distance analogues by acorresponding factor for a largest calculated distance d. For example,processing circuitry may apply the equation V_(D0)×f=d_(D0), where f isa scaling factor to be applied to all electrical distance analogues V toincrease the accuracy of the determined distances d between electrodes94, 96.

In other examples, processing circuitry 80 simultaneously uses both thedetermined distance d_(XY) and the determined voltage difference V_(XY)for each pair of electrodes 94, 96 to standardize the spatialrelationships between electrodes 94, 96, normalize the spatialrelationships between electrodes 94, 96, etc.

In examples where the electrical stimulus is a cardiac signal sensedfrom a heart of patient 12, the heart has a known, fixed position withinthe body of patient 12. IMD 14 may therefore use the determined distanced_(XY) and the determined voltage difference V_(XY) for each pair ofelectrodes 94, 96 to determine spatial relationships between each pairof electrodes 94, 96, such that IMB 14 may determine relative positionsof each electrode 94, 96 to each other electrode 94, 96. Furthermore,IMB 14 may use the determined distance d_(XY) and the determined voltagedifference V_(XY) for each pair of electrodes 94, 96 to determinespatial relationships between each pair of electrodes 94, 96 and theheart of patient 12 so as to determine absolute positions of eachelectrode 94, 96 to each other electrode 94, 96 within the body ofpatient 12.

The following examples are described herein.

Example 1. A method comprising: controlling, by processing circuitry ofa medical device, stimulation generation circuitry to deliver, via afirst electrode of a plurality of electrodes, an electrical stimulus;sensing, by sensing circuitry and for each other electrode of theplurality of electrodes, a respective electrical signal indicative ofthe electrical stimulus; determining, by the processing circuitry andfor each other electrode, a respective value for each respectiveelectrical signal; and determining, by the processing circuitry, andbased on the respective values for each respective electrical signalsensed by each other electrode of the plurality of electrodes, spatialrelationships between the first electrode and each other electrode ofthe plurality of electrodes.

Example 2. The method of example 1, further comprising: selecting, bythe processing circuitry and based on the spatial relationships betweenthe first electrode and each other electrode of the plurality ofelectrodes, at least one electrode of the plurality of electrodes; andcontrolling, by the processing circuitry, the stimulation generationcircuitry to deliver, via the selected at least one electrode,electrical stimulation therapy to the patient.

Example 3. The method of any of examples 1 through 2, furthercomprising: selecting, by the processing circuitry and based on thespatial relationships between the first electrode and each otherelectrode of the plurality of electrodes, at least one electrode of theplurality of electrodes; and sensing, by the processing circuitry andvia the selected at least one electrode, at least one biosignal of thepatient.

Example 4. The method of any of examples 1 through 2, whereincontrolling the stimulation generation circuitry to deliver theelectrical stimulus comprises controlling the stimulation generationcircuitry to deliver an electrical stimulus defined by a first voltageamplitude value; wherein sensing, for each other electrode of theplurality of electrodes, the respective electrical signal indicative ofthe electrical stimulus comprises sensing, for each other electrode ofthe plurality of electrodes, electrical signals indicative of secondvoltage amplitude values indicative of the electrical stimulus, andwherein determining the spatial relationships between the firstelectrode and each other electrode of the plurality of electrodescomprises determining, based on the first voltage amplitude value andthe electrical signals indicative of the second voltage amplitudevalues, the spatial relationships between the first electrode and eachother electrode of the plurality of electrodes.

Example 5. The method of any of examples 1 through 2, whereindetermining, based on the respective values for each respectiveelectrical signal sensed by each other electrode of the plurality ofelectrodes, the spatial relationships between the first electrode andeach other electrode of the plurality of electrodes comprises:determining, based on a respective values for a respective electricalsignal sensed by a second electrode and a value of a tissue conductivityof a tissue of a patient interposed between the first electrode and thesecond electrode, a spatial relationship between the first electrode andthe second electrode.

Example 6. The method of example 5, further comprising: sensing, by thesensing circuitry, a value of an impedance between the first electrodeand the second electrode of the plurality of electrodes; determining, bythe processing circuitry and based on the sensed value of the impedance,a type of a tissue interposed between the first electrode and the secondelectrode, and determining, by the processing circuitry and based on thetype of the tissue interposed between the first electrode and the secondelectrode, the value of the tissue conductivity of the tissue of thepatient interposed between the first electrode and the second electrode.

Example 7. The method of any of examples 5 through 6, wherein the typeof the tissue interposed between the first electrode and the secondelectrode is one of a nerve tissue, a bone tissue, a connective tissue,or an adipose tissue.

Example 8. The method of any of examples 1 through 7, further comprisingoutputting, by the processing circuitry and for display to a user, arepresentation of the plurality of electrodes depicting a spatialrelationship between at least two of the plurality of electrodes.

Example 9. The method of example 8, wherein the representation of theplurality of electrodes depicting the spatial relationship between atleast two of the plurality of electrodes comprises a representation ofthe plurality of electrodes depicting the spatial relationship betweenat least two of the plurality of electrodes in 3 dimensions.

Example 10. The method of any of examples 1 through 9, wherein thespatial relationships between the first electrode and each otherelectrode of the plurality of electrodes comprise distances between thefirst electrode and each other electrode of the plurality of electrodes.

Example 11. The method of any of examples 1 through 10, wherein theplurality of electrodes are disposed on a plurality of leads.

Example 12. The method of any of examples 1 through 11, wherein theplurality of electrodes are implanted within an epidural space of thepatient.

Example 13. The method of any of examples 1 through 12, wherein animplantable medical device comprises the stimulation generationcircuitry and the processing circuitry.

Example 14. The method of any of claims 1 through 13, furthercomprising: sensing, by the sensing circuitry and for each electrode ofthe plurality of electrodes, a respective second electrical signalindicative of a cardiac signal of a heart of a patient; determining, bythe processing circuitry and for each electrode of the plurality ofelectrodes, a respective second value for each respective electricalsignal; and determining, by the processing circuitry and based on therespective second values for each respective second electrical signalsensed by each electrode of the plurality of electrodes, a spatialrelationship between each electrode of the plurality of electrodes andthe heart of the patient.

Example 15. A medical device system comprising: stimulation generationcircuitry configured to deliver electrical stimulation via a firstelectrode of a plurality of electrodes; and processing circuitryconfigured to control the stimulation generation circuitry to deliver,via the first electrode, an electrical stimulus; sensing circuitryconfigured to sense, for each other electrode of the plurality ofelectrodes, a respective electrical signal indicative of the electricalstimulus, wherein the processing circuitry is further configured todetermine, for each other electrode, a respective value for eachrespective electrical signal, and wherein the processing circuitry isfurther configured to determine, based on the respective values for eachrespective electrical signal sensed by each other electrode of theplurality of electrodes, spatial relationships between the firstelectrode and each other electrode of the plurality of electrodes.

Example 16. The system of example 15, wherein the processing circuitryis further configured to: select, based on the spatial relationshipsbetween the first electrode and each other electrode of the plurality ofelectrodes, at least one electrode of the plurality of electrodes; andcontrol the stimulation generation circuitry to deliver, via theselected at least one electrode, electrical stimulation therapy to thepatient.

Example 17. The system of any of examples 15 through 16, wherein todetermine, based on the respective values for each respective electricalsignal sensed by each other electrode of the plurality of electrodes,the spatial relationships between the first electrode and each otherelectrode of the plurality of electrode, the processing circuitry isconfigured to: determine, based on a respective values for a respectiveelectrical signal sensed by a second electrode and a value of a tissueconductivity of a tissue of a patient interposed between the firstelectrode and the second electrode, a spatial relationship between thefirst electrode and the second electrode.

Example 18. The system of any of examples 15 through 17, furthercomprising an external programmer configured to output, for display to auser, a representation of the plurality of electrodes depicting aspatial relationship between at least two of the plurality ofelectrodes.

Example 19. The system of any of examples 15 through 18, wherein theplurality of electrodes are disposed on a plurality of leads.

Example 20. The system of any of examples 15 through 19, wherein animplantable medical device comprises the stimulation generationcircuitry, the processing circuitry, and the sensing circuitry.

Example 21. The system of any of examples 15 through 20, wherein thesensing circuitry is further configured to sense, for each electrode ofthe plurality of electrodes, a respective second electrical signalindicative of a cardiac signal of a heart of a patient, wherein theprocessing circuitry is further configured to determine, for eachelectrode of the plurality of electrodes, a respective second value foreach respective electrical signal, and wherein the processing circuitryis further configured to determine, based on the respective secondvalues for each respective second electrical signal sensed by eachelectrode of the plurality of electrodes, a spatial relationship betweeneach electrode of the plurality of electrodes and the heart of thepatient.

Example 22. A non-transitory computer-readable medium comprisinginstructions that, when executed, are configured to cause processingcircuitry of a medical device to: control stimulation generationcircuitry of the medical device to deliver, via a first electrode of aplurality of electrodes, an electrical stimulus; control sensingcircuitry to sense, for each other electrode of the plurality ofelectrodes, a respective electrical signal indicative of the electricalstimulus; determine, for each other electrode, a respective value foreach respective electrical signal; and determine, based on therespective values for each respective electrical signal sensed by eachother electrode of the plurality of electrodes, spatial relationshipsbetween the first electrode and each other electrode of the plurality ofelectrodes.

Example 23. A method comprising: sensing, by sensing circuitry of amedical device and for each electrode of a plurality of electrodes, arespective electrical signal indicative of a cardiac signal of a heartof a patient; determining, by the processing circuitry and for eachelectrode of the plurality of electrodes, a respective value for eachrespective electrical signal; and determining, by the processingcircuitry, and based on the respective values for each respectiveelectrical signal sensed by each electrode of the plurality ofelectrodes, a spatial relationship between each electrode of theplurality of electrodes and the heart of the patient.

Example 24. The method of example 23, further comprising: selecting, bythe processing circuitry and based on the spatial relationship betweeneach electrode of the plurality of electrodes and the heart of thepatient, at least one electrode of the plurality of electrodes; andcontrolling, by the processing circuitry, stimulation generationcircuitry to deliver, via the selected at least one electrode,electrical stimulation therapy to the patient.

Example 25. The method of any of examples 23 through 24, furthercomprising: selecting, by the processing circuitry and based on thespatial relationship between each electrode of the plurality ofelectrodes and the heart of the patient, at least one electrode of theplurality of electrodes; and sensing, by the processing circuitry andvia the selected at least one electrode, at least one biosignal of thepatient.

Example 26. The method of examples 23 through 25, further comprising:controlling, by the processing circuitry, stimulation generationcircuitry to deliver, via a first electrode of the plurality ofelectrodes, an electrical stimulus; sensing, by the sensing circuitryand for each other electrode of the plurality of electrodes, arespective second electrical signal indicative of the electricalstimulus; determining, by the processing circuitry and for each otherelectrode, a respective second value for each respective secondelectrical signal; and determining, by the processing circuitry, andbased on the respective second values for each respective secondelectrical signal sensed by each electrode of the plurality ofelectrodes, spatial relationships between the first electrode and eachother electrode of the plurality of electrodes.

Example 27. A medical device system comprising: sensing circuitry of amedical device configured to sense, for each electrode of a plurality ofelectrodes, a respective electrical signal indicative of a cardiacsignal of a heart of a patient; and processing circuitry configured to:determine, for each electrode of the plurality of electrodes, arespective value for each respective electrical signal; and determine,based on the respective values for each respective electrical signalsensed by each other electrode of the plurality of electrodes, a spatialrelationship between each electrode of the plurality of electrodes andthe heart of the patient.

Example 28. The system of example 27, wherein the processing circuitryis further configured to: select, based on the spatial relationshipbetween each electrode of the plurality of electrodes and the heart ofthe patient, at least one electrode of the plurality of electrodes; andcontrol the stimulation generation circuitry to deliver, via theselected at least one electrode, electrical stimulation therapy to thepatient.

Example 29. The system of any of examples 27 through 28, wherein theprocessing circuitry is further configured to: select, based on thespatial relationship between each electrode of the plurality ofelectrodes and the heart of the patient, at least one electrode of theplurality of electrodes; and control, by the processing circuitry, thesensing circuitry to sense, via the selected at least one electrode, atleast one biosignal of the patient.

Example 30. The system of any of examples 27 through 29, wherein theprocessing circuitry is further configured to control the stimulationgeneration circuitry to deliver, via a first electrode of the pluralityof electrodes, an electrical stimulus, wherein the sensing circuitry isfurther configured to sense, for each other electrode of the pluralityof electrodes, a respective second electrical signal indicative of theelectrical stimulus, wherein the processing circuitry is furtherconfigured to determine, for each other electrode, a respective secondvalue for each respective second electrical signal, and wherein theprocessing circuitry is further configured to determine, based on therespective second values for each respective second electrical signalsensed by each other electrode of the plurality of electrodes, spatialrelationships between the first electrode and each other electrode ofthe plurality of electrodes.

It should be understood that various aspects disclosed herein may becombined in different combinations than the combinations specificallypresented in the description and accompanying drawings. It should alsobe understood that, depending on the example, certain acts or events ofany of the processes or methods described herein may be performed in adifferent sequence, may be added, merged, or left out altogether (e.g.,all described acts or events may not be necessary to carry out thetechniques). In addition, while certain aspects of this disclosure aredescribed as being performed by a single module or unit for purposes ofclarity, it should be understood that the techniques of this disclosuremay be performed by a combination of units or modules associated with,for example, a medical device.

In one or more examples, the described techniques may be implemented inhardware, software, firmware, or any combination thereof. If implementedin software, the functions may be stored as one or more instructions orcode on a computer-readable medium and executed by a hardware-basedprocessing unit. Computer-readable media may include non-transitorycomputer-readable media, which corresponds to a tangible medium such asdata storage media (e.g., RAM, ROM, EEPROM, flash memory, or any othermedium that can be used to store desired program code in the form ofinstructions or data structures and that can be accessed by a computer).

Instructions may be executed by one or more processors, such as one ormore digital signal processors (DSPs), general purpose microprocessors,application specific integrated circuits (ASICs), field programmablelogic arrays (FPGAs), or other equivalent integrated or discrete logiccircuitry. Accordingly, the term “processor” as used herein may refer toany of the foregoing structure or any other physical structure suitablefor implementation of the described techniques. Also, the techniquescould be fully implemented in one or more circuits or logic elements.

Various examples have been described. These and other examples arewithin the scope of the following claims.

What is claimed is:
 1. A method comprising: sensing, by sensingcircuitry of a medical device and via each electrode of a plurality ofelectrodes, a respective electrical signal indicative of a cardiacsignal of a heart of a patient; determining, by the processing circuitryand for each electrode of the plurality of electrodes, a respectivevalue for each respective electrical signal; and determining, by theprocessing circuitry, and based on the respective values for eachrespective electrical signal sensed by each electrode of the pluralityof electrodes, a spatial relationship between each electrode of theplurality of electrodes and each other electrode of the plurality ofelectrodes.
 2. The method of claim 1, further comprising: selecting, bythe processing circuitry and based on the spatial relationship betweeneach electrode of the plurality of electrodes and each other electrodeof the plurality of electrodes, at least one electrode of the pluralityof electrodes; and controlling, by the processing circuitry, stimulationgeneration circuitry to deliver, via the selected at least oneelectrode, electrical stimulation therapy to the patient.
 3. The methodof claim 1, further comprising: selecting, by the processing circuitryand based on the spatial relationship between each electrode of theplurality of electrodes and each other electrode of the plurality ofelectrodes, at least one electrode of the plurality of electrodes; andsensing, by the processing circuitry and via the selected at least oneelectrode, at least one biosignal of the patient.
 4. The method of claim1, wherein determining the spatial relationship between each electrodeof the plurality of electrodes and each other electrode of the pluralityof electrodes comprises: obtaining a known location of the heart withinthe patient; and determining, based on the known location of the heartand the respective values for each respective electrical signal sensedby each electrode of the plurality of electrodes, the spatialrelationship between each electrode of the plurality of electrodes andeach other electrode of the plurality of electrodes.
 5. The method ofclaim 1, further comprising: controlling, by the processing circuitry,stimulation generation circuitry to deliver, via a first electrode ofthe plurality of electrodes, an electrical stimulus; sensing, by thesensing circuitry and for each other electrode of the plurality ofelectrodes, a respective second electrical signal indicative of theelectrical stimulus; determining, by the processing circuitry and foreach other electrode, a respective second value for each respectivesecond electrical signal; and determining, by the processing circuitryand based on both the respective second values for each respectivesecond electrical signal sensed by each electrode of the plurality ofelectrodes and the respective values for each respective electricalsignal indicative of the cardiac signal, the spatial relationshipsbetween the first electrode and each other electrode of the plurality ofelectrodes.
 6. The method of claim 1, further comprising outputting, bythe processing circuitry and for display to a user, a representation ofthe plurality of electrodes depicting the spatial relationship betweenat least two of the plurality of electrodes.
 7. The method of claim 6,wherein the representation of the plurality of electrodes depicting thespatial relationship between at least two of the plurality of electrodescomprises a representation of the plurality of electrodes depicting thespatial relationship between at least two of the plurality of electrodesin 3 dimensions.
 8. The method of claim 1, wherein the plurality ofelectrodes are disposed on a plurality of leads.
 9. The method of claim1, wherein the plurality of electrodes are implanted within an epiduralspace of a patient.
 10. A medical device system comprising: sensingcircuitry configured to sense, via each electrode of a plurality ofelectrodes, a respective electrical signal indicative of a cardiacsignal of a heart of a patient; and processing circuitry configured to:determine, for each electrode of the plurality of electrodes, arespective value for each respective electrical signal; and determine,based on the respective values for each respective electrical signalsensed by each other electrode of the plurality of electrodes, a spatialrelationship between each electrode of the plurality of electrodes andeach other electrode of the plurality of electrodes.
 11. The system ofclaim 10, wherein the processing circuitry is further configured todetermine, based on the respective values for each respective electricalsignal sensed by each electrode of the plurality of electrodes, aspatial relationship between each electrode of the plurality ofelectrodes and the heart of the patient.
 12. The system of claim 10,wherein the processing circuitry is further configured to: select, basedon the spatial relationship between each electrode of the plurality ofelectrodes and each other electrode of the plurality of electrodes, atleast one electrode of the plurality of electrodes; and control thestimulation generation circuitry to deliver, via the selected at leastone electrode, electrical stimulation therapy to the patient.
 13. Thesystem of claim 10, wherein the processing circuitry is furtherconfigured to: select, based on the spatial relationship between eachelectrode of the plurality of electrodes and the heart of the patient,at least one electrode of the plurality of electrodes; and control, bythe processing circuitry, the sensing circuitry to sense, via theselected at least one electrode, at least one biosignal of the patient.14. The system of claim 10, wherein the processing circuitry is furtherconfigured to control the stimulation generation circuitry to deliver,via a first electrode of the plurality of electrodes, an electricalstimulus, wherein the sensing circuitry is further configured to sense,for each other electrode of the plurality of electrodes, a respectivesecond electrical signal indicative of the electrical stimulus, whereinthe processing circuitry is further configured to determine, for eachother electrode, a respective second value for each respective secondelectrical signal, and wherein the processing circuitry is furtherconfigured to determine, based on both the respective second values foreach respective second electrical signal sensed by each other electrodeof the plurality of electrodes and the respective values for eachrespective electrical signal indicative of the cardiac signal, thespatial relationships between the first electrode and each otherelectrode of the plurality of electrodes.
 15. The system of claim 10,further comprising outputting, by the processing circuitry and fordisplay to a user, a representation of the plurality of electrodesdepicting the spatial relationship between at least two of the pluralityof electrodes.
 16. The system of claim 15, wherein the representation ofthe plurality of electrodes depicting the spatial relationship betweenat least two of the plurality of electrodes comprises a representationof the plurality of electrodes depicting the spatial relationshipbetween at least two of the plurality of electrodes in 3 dimensions. 17.The system of claim 10, wherein the plurality of electrodes are disposedon a plurality of leads.
 18. The system of claim 10, further comprisingthe plurality of electrodes configured to be implanted within anepidural space of a patient.
 19. The system of claim 10, furthercomprising an implantable medical device comprising the stimulationgeneration circuitry and the processing circuitry.
 20. A non-transitorycomputer-readable medium comprising instructions that, when executed,are configured to cause processing circuitry of a medical device to:control sensing circuitry to sense, via each electrode of a plurality ofelectrodes, a respective electrical signal indicative of a cardiacsignal of a heart of a patient; determine, for each electrode of theplurality of electrodes, a respective value for each respectiveelectrical signal; and determine, based on the respective values foreach respective electrical signal sensed by each other electrode of theplurality of electrodes, a spatial relationship between each electrodeof the plurality of electrodes and each other electrode of the pluralityof electrodes.